package com.web.jq.controller;



import java.util.List;


import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;


import com.web.jq.pojo.User;
import com.web.jq.respone.Result;
import com.web.jq.service.UserService;

import net.sf.json.JSONArray;


@Controller
public class UserController {
@Autowired
private UserService userService;



@CrossOrigin(allowCredentials = "true",allowedHeaders = "*")
@ResponseBody
@RequestMapping("/Login")
public Object findUser(String id,String password) {
List<User> user=userService.findUser();
if (user!=null) {
	

return Result.success(user);

}
else {
	return "失败";
}

}


}
